<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>小竹财税</title>
</head>

<body>
    <script>
        function GetQueryString(name) {
            var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)");
            var r = window.location.search.substr(1).match(reg);
            if (r != null) return unescape(r[2]);
            return null;
        }
        let go = ''
        if (GetQueryString('url')) {
            var url = GetQueryString('url') // 获取下个页面地址
            go += url
        }
        if (GetQueryString('code')) {
            var code = GetQueryString('code')
            localStorage.setItem('usercode', code)
        }
        // if (GetQueryString('queryName')) {
        //     var queryName = GetQueryString('queryName')
        //     go += `?${queryName}=${GetQueryString(queryName)}`
        // }
        console.log(go)
        // if (window.location.href.startsWith('http://'))
        //     window.location.replace('http://' + go);
        // if (window.location.href.startsWith('https://'))
        //     window.location.replace('https://' + go);
        window.location.replace(go);

        // console.log(window.location.host)
        // window.location.replace("https://www.dududu.com");
    </script>
</body>

</html>